#include <string.h>
#include <stdio.h>
#include <stdlib.h>
#include "pdu.h"
#include "atcmd.h" 
#include "type.h"

int main ( int argc, char *argv[] )
{    
    int ret = -1;
    int smsindex = -1;
    
    ret = sim800l_serial_init(115200);
    if ( ret < 0 )
    {
        printf("init seial port error\n");
        return -1;
    }
    
    //sim800l_send_sms(EN_TEXT, "13670042463", argv[1]);
    //sim800l_send_sms(EN_PDU, "13670042463", argv[1]);
    smsindex = sim800l_listen_sms();
    printf("smsindex:%d\n",smsindex);
    ret = sim800l_get_sms(smsindex);
    printf("ret:%d\n",ret);

    
    sim800l_close();

	return 0;
} 
